#!/bin/bash

# 新闻平台基础服务启动脚本
# Author: Logan.Li

set -e

echo "启动基础服务: MySQL、Redis、Nacos"

# 启动服务
docker-compose up -d mysql redis nacos

# 等待服务就绪
echo "等待服务启动..."
sleep 30

echo ""
echo "服务已启动！"
echo "- MySQL: localhost:3306 (root/root123456)"
echo "- Redis: localhost:6379"
echo "- Nacos: http://localhost:8848/nacos (nacos/nacos)"
echo ""
echo "查看状态: docker-compose ps"
echo "停止服务: docker-compose down"
